package xuegao.study.mall.admin.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import xuegao.study.mall.common.api.CommonResult;
import xuegao.study.mall.common.vo.pms.PmsMemberLevelVo;

import java.util.ArrayList;
import java.util.List;

@RestController
@RequestMapping("/memberLevel")
public class PmsMemberLevelController {

    @GetMapping("/list")
    public CommonResult<List<PmsMemberLevelVo>> getList() {
        List<PmsMemberLevelVo> voList = new ArrayList<>();
        PmsMemberLevelVo vo1 = new PmsMemberLevelVo();
        vo1.setMemberLevelId(1001L);
        vo1.setMemberLevelName("黄金会员");
        PmsMemberLevelVo vo2 = new PmsMemberLevelVo();
        vo2.setMemberLevelId(1002L);
        vo2.setMemberLevelName("白金会员");
        PmsMemberLevelVo vo3 = new PmsMemberLevelVo();
        vo3.setMemberLevelId(1003L);
        vo3.setMemberLevelName("钻石会员");
        voList.add(vo1);
        voList.add(vo2);
        voList.add(vo3);
        return CommonResult.success(voList);
    }

}
